package com.jdrx.sw.sewage.beans.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDateTime;

@Data
@ApiModel(value = "NewsPO", description = "新闻")
public class NewsPO implements Serializable {
    private static final long serialVersionUID = 8202346644170934626L;

    @ApiModelProperty(value = "id")
    private Long id;

    @ApiModelProperty(value = "标题")
    private String title;

    @ApiModelProperty(value = "新闻内容", hidden = true)
    private String newsContent;

    @ApiModelProperty(value = "更新时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME, pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateAt;

    @ApiModelProperty(value = "更新人id")
    private Long updateById;

    @ApiModelProperty(value = "更新人")
    private String updateBy;
}